/*=====================================================================================================================
                    Copyright(c) 2009 Geometric PLM Software Corp. All rights reserved.
                             Unpublished - All rights reserved
=======================================================================================================================
File description:
    Filename: tc_type.h
    Module  : (geometric) itk module.

        This file manages the tctype operations..

=======================================================================================================================
Date               Name              Description of Change
14-Jul-2009        Penn,Xie          Initialize creation
$HISTORY$
=====================================================================================================================*/
#ifndef GITK_TC_TYPE_H
#define GITK_TC_TYPE_H


#include <tccore\workspaceobject.h>

#ifdef __cplusplus
    extern "C"
    {
#endif

    /**
    * Is the object type of the workspaceobject tag the appointed typeName?
    * @param wsoTag   - <I> tag of the workspaceobject
    * @param typeName - <I> type name
    * @param isType   - <O> Is the matched type?
    * @return - ITK_Ok or error code,The answer is TRUE if the object type of the given object tag is type_tag or is a subtype of type_tag.
    */
    extern int GTCTYPE_is_type_of( tag_t wsoTag, const char *typeName, logical *isType );

    /**
    * Is the object type of the workspaceobject tag the appointed typeName?
    * @param wsoTag   - <I> tag of the workspaceobject
    * @param typeName - <I> type name
    * @param isType   - <O> Is the matched type?
    * @return - ITK_Ok or error code,The answer is FALSE if the object type of the given object tag is type_tag or is a subtype of type_tag.
    */
    extern int GTCTYPE_is_definite_type_of( tag_t wsoTag, const char *typeName, logical *isType );

    /**
    * Is the group name of the workspaceobject tag the appointed group name?
    * @param wsoTag    - <I> tag of the workspaceobject
    * @param groupName - <I> group name
    * @param isGroupOwner - <O> Is the matched type?
    * @return - ITK_Ok or error code,The answer is FALSE if the object type of the given object tag is type_tag or is a subtype of type_tag.
    */
    extern int GTCTYPE_is_owner_group( tag_t wsoTag, const char *groupName, logical *isGroupOwner );

    /**
    * Get the master name from item (type)name or item revision (type)name
    * @param itemNameOrItemRevName - <I> item name or item revision name
    * @param masterName            - <O> the master name
    * @return - ITK_ok or error code
    */
    extern int GTCTYPE_get_master_name( const char *itemNameOrItemRevName, char masterName[WSO_name_size_c + 1] );

    /**
    * Get the class name of one form type
    * @param itemRevName - <I> item revision name
    * @param className   - <O> the class name
    * @return - ITK_ok or error code
    */
    extern int GTCTYPE_get_form_class_name( const char *itemRevName, char className[WSO_name_size_c + 1] );

#ifdef __cplusplus
    }
#endif


#endif //GITK_TC_TYPE_H
